{% extends "base.html" %}

{% block head-title %}{{algorithm.algorithm_name}}{% endblock %}

{% block title %}{{algorithm.algorithm_name}}{% endblock %} 

{% block content %}
<script src="/static/js/preprocessor/3.js"></script>
<form action="/preprocessor/configure_parameters/" method="post" class="uk-form" id="form1"
					onsubmit="return onForm1Submit();">
	{%csrf_token%}
	<input type="hidden" name="instance_id" value="{{algorithm.instance_id}}"/>
	<fieldset>
		<legend>配置参数(3/3)</legend>
			{% ifequal algorithm.algorithm_name "去重" %}
				<div class="uk-form-row">
					<div class="uk-form-controls">
						重复数据:
						<select name="keep">
							<option value="first" selected>保留首项</option>
							<option value="last">保留尾项</option>
							<option value="False">全部去除</option>
						</select>
					</div>
				</div>
			{% endifequal %}
			{% ifequal algorithm.algorithm_name "缺失值" %}
				{% for type in algorithm.input_field_types %}
				<div class="uk-form-row">
					<div class="uk-form-controls">
						{{ type.0 }}:
						<select name="methods">
							{% if type.1 == "float64" or type.1 == "int64" %}
							<option value="mode" selected>众数</option>
							<option value="mean">均值</option>
							<option value="median">中位数</option>
							<option value="dropna">删除</option>
							{% else %}
							<option value="mode" selected>众数</option>
							<option value="dropna">删除</option>
							{% endif %}
						</select>
					</div>
				</div>
				{% endfor %}
			{% endifequal %}
			
	</fieldset>
	<div class="uk-form-row" style="margin-top:5px;">
		<a href="javascript:history.go(-1);" class="uk-button">上一步</a>
		<input class="uk-button uk-button-primary" type="submit"
			value="提交" style="float: right;">
	</div>
</form>
{% endblock %}